<!DOCTYPE html>
<html lang="zh-CN">

<head>
	<meta charset="UTF-8" />
	<meta http-equiv="X-UA-Compatible" content="IE=edge" />
	<meta name="viewport" content="width=device-width, initial-scale=1.0" />
	<title>就诊系统主页</title>
	<link rel="stylesheet" href="../static/bootstrap/css/bootstrap.min.css" />
	<link rel="stylesheet" href="../static/css/patient.css" />
	<link rel="stylesheet" href="../static/css/global.css" />
</head>

<body>
	<!--导航栏-->
	<nav th:fragment="patNav" class="navber bg-body-tertiary rounded py-3 position-fixed w-100">
		<div class="container d-flex">
			<a class="navber-brand logolink" th:href="@{/}"> <img src="../static/img/hospital-logo.svg" alt="hospital"
					width="36" height="36" /> <strong class="">自助就诊·查询系统</strong>
			</a>
			<ul class="laptop nav nav-pills">
				<li class="nav-item mx-3"><a class="nav-link text-secondary"></a></li>
				<li class="nav-item mx-3"><a class="nav-link text-secondary" aria-current="page"
						th:href="@{/registered}">挂号缴费</a></li>
				<li class="nav-item mx-3"><a class="nav-link text-secondary" th:href="@{/payment}">结算缴费</a></li>
				<li class="nav-item mx-3"><a class="nav-link text-secondary" th:href="@{/medicalRecord}">病历查询</a></li>
				<li class="nav-item mx-3"><a class="nav-link text-secondary" th:href="@{/prescription}">处方查看</a></li>
			</ul>
		</div>
	</nav>
	<!--可切换的子页面组件-->
	<main class="mainBox">
		<div class="container shadow-sm">
			<section th:fragment="patLoginStatus"
				class="border rounded p-3 d-flex justify-content-between align-items-center">
				<strong> 当前状态： <span th:switch="${loginStatus}"> <em class="text-success" th:case=true>已登录</em> <em
							class="text-danger" th:case=false>未登录</em>
					</span>
				</strong>
				<button class="btn btn-outline-secondary btn-sm">
					<span th:switch="${loginStatus}"> <a th:href="@{/patient/login}" th:case=false>点我登录</a> <a
							th:href="@{/patient/logout}" th:case=true>点我退出</a>
					</span>
				</button>
			</section>
			<article class="py-3 text-center d-flex flex-wrap justify-content-center">
				<a class="card" th:href="@{/patient/registered}"> <img src="/static/img/logo-register.svg"
						alt="logo-register" class="card-img-top" width="128" height="128" />
					<div class="card-body">
						<h4 class="card-title">挂号缴费</h4>
						<p class="card-text">线上挂号系统。填写患者信息，选择科室，缴纳挂号费后即可获取挂号编码</p>
					</div>
				</a> <a class="card" th:href="@{/payment}"> <img src="/static/img/logo-payment.svg" alt="logo-register"
						class="card-img-top" width="128" height="128" />
					<div class="card-body">
						<h4 class="card-title">结算缴费</h4>
						<p class="card-text">医生开完处方后，可从此处结算，根据缴费单据去药物出纳窗口获取药物。</p>
					</div>
				</a> <a class="card" th:href="@{/patient/medicalRecord}"> <img src="/static/img/logo-record.svg"
						alt="logo-register" class="card-img-top" width="128" height="128" />
					<div class="card-body">
						<h4 class="card-title">病历查询</h4>
						<p class="card-text">可查询自己的就诊记录，有效时限2年。</p>
					</div>
				</a> <a class="card" th:href="@{/patient/prescription}"> <img src="/static/img/logo-precription.svg"
						alt="logo-register" class="card-img-top" width="128" height="128" />
					<div class="card-body">
						<h4 class="card-title">处方查看</h4>
						<p class="card-text">可查询医生为自己的开的处方单据，有效时间2年。</p>
					</div>
				</a> <a class="card" th:href="@{/patient/personal}"> <img src="/static/img/logo-userInfo.svg"
						alt="logo-register" class="card-img-top" width="128" height="128" />
					<div class="card-body">
						<h4 class="card-title">个人信息</h4>
						<p class="card-text">您可以在此调整您的个人信息，为了诊断更加准确，请填写真实信息。</p>
					</div>
				</a>
			</article>
		</div>
	</main>
	<script src="../static/bootstrap/js/bootstrap.bundle.min.js"></script>
	<script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
	<script type="text/javascript">
		function toLoginPage() {
			console.log(1);
			axios.get("/login");
		}
	</script>
</body>

</html>